package Solution_3;

public class InternetServer extends Server implements  InternetService{

    public InternetServer(double data){
        this.data =data;
    }
    public double getData() {
        return data;
    }

    public void setData(double data) {
        this.data = data;
    }

    private  double data;
    @Override
    public void show() {
        System.out.println(" 这是上网套餐信息 :\n" +  " 上网流量 : "  +  getData()+ "MB 每月资费 ： " + getPriceByMonth() + "元");
    }

    @Override
    public void internet(double data, Card card) {
        System.out.println("当前卡是");
        card.show();
        System.out.println("它实现了上网服务接口");
    }

    @Override
    public void consume() {
        System.out.println("这是上网消费信息");
    }
}
